﻿using System;
using UnityEngine.SceneManagement;

namespace Framework.Resource
{

    /// <summary>
    /// 资源辅助类
    /// </summary>
    public interface IResourceHelper
    {
        public void InitResource(InitResourceCallback callback);
        public void UpdateResourceVersion(UpdateResourceVersionCallback versionCallback);
        public void LoadAsset<T>(string assetName,LoadAssetCallback callback,object userData) where T : UnityEngine.Object;
        public void LoadAsset(string assetName, Type assetType,LoadAssetCallback callback,object userData);
        public void UnloadAsset(string assetName,UnloadAssetCallback callback);
        public void UnloadAsset(Object asset,UnloadAssetCallback callback);
        public void LoadScene(string sceneName,LoadSceneCallback callback, LoadSceneMode mode , bool suspendLoad );
        public void UnLoadScene(string sceneName,UnloadSceneCallback callback);
        public void UnLoadUnusedAssets(UnLoadUnusedAssetsCallback callback);

        public T LoadAssetSync<T>(string assetName) where T : UnityEngine.Object;
        public Object LoadAssetSync(string assetName,Type assetType);

        public void DownRemoteResource(DownloadCallback downloadCallback);

    }

}